package com.hzgj.bcl.soa.config;

import java.io.Serializable;

import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

import static com.hzgj.bcl.soa.util.Constants.DEFAULT_CONNECTTIMEOUT;
import static com.hzgj.bcl.soa.util.Constants.DEFAULT_LOADBALANCE;
import static com.hzgj.bcl.soa.util.Constants.DEFAULT_MSBEFORERETRY;
import static com.hzgj.bcl.soa.util.Constants.DEFAULT_REQUESTTIMEOUT;
import static com.hzgj.bcl.soa.util.Constants.DEFAULT_RETRIES;

/**
 * Created by warning5 on 2017/3/1.
 */
@Getter
@Setter
@ToString
public class ClientConfig implements Serializable {

    private int connectTimeoutInMills = DEFAULT_CONNECTTIMEOUT;
    private int requestTimeoutInMills = DEFAULT_REQUESTTIMEOUT;
    /**
     * 重试次数
     */
    private int retries = DEFAULT_RETRIES;
    /**
     * 重试时间间隔
     */
    private int msBeforeRetry = DEFAULT_MSBEFORERETRY;//20ms;

    private String loadbalance = DEFAULT_LOADBALANCE;

}
